Once the product is established as a set, we apply either the weak or the strong product topology. You should be familiar with this before we proceed.
The indexing set J doesn't have to be ordered; it's just convenient. Let J be the set containing apple, orange, and banana, and assume these three fruits are associated with three separate topological spaces. The product consists of functions on J, mapping apple into Sapple, orange into Sorange, and banana into Sbanana.
Let J be a topological space. Its points may be ordered, or not. In any case, each point i ∈ J is associated with a space Si, and the product space P, as a set, is the collection of functions on J, where each point i is mapped into Si.
So far so good, but what about the topology? Since J is a topological space, P can be given the "compact product topology", as follows.
Let V be a compact set in J. For each i ∈ V, select a base open set in Si. In other words, functions on J must map i into the base open set Bi in Si. The other components are unconstrained. As usual, we have to prove this is a base.
Let f be a point in the product space P, which is really a function on J, such that f is in the intersection of two base open sets. One base set comes from V in J, and the other comes from W. The first specifies Bi in Si for each i in V, the second specifies Ci in Si for each i in W. When i is in V∩W, f(i) belongs to Bi and Ci simultaneously. We want to put an open set around f, but still inside our intersection.
Let U = V∪W, another compact set in J. For each i in U, select a base open set of Si that is contained in Bi, or Ci, or both. This fits neatly into the intersection, and contains f. The intersection is covered by base open sets, and we have a base for the compact product topology.
Give J the discrete topology, and any finite set of points in J is compact. A base open set in P is the cross product of finitely many base sets Bi in Si, with all other components unconstrained. This is the weak product topology.
If J itself is compact, every i in J contributes an open set Bi to the product. This is the strong product topology. If each space Si is discrete, the strong product topology gives a discrete space.